<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.3.1"/>
<title>Open Event Machine API: test_appl_perf.c</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">Open Event Machine API
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.3.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('test_appl_perf_8c-example.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">test_appl_perf.c</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><span class="comment">/*</span></div>
<div class="line"><span class="comment"> *   Copyright (c) 2012, Nokia Siemens Networks</span></div>
<div class="line"><span class="comment"> *   All rights reserved.</span></div>
<div class="line"><span class="comment"> *</span></div>
<div class="line"><span class="comment"> *   Redistribution and use in source and binary forms, with or without</span></div>
<div class="line"><span class="comment"> *   modification, are permitted provided that the following conditions are met:</span></div>
<div class="line"><span class="comment"> *       * Redistributions of source code must retain the above copyright</span></div>
<div class="line"><span class="comment"> *         notice, this list of conditions and the following disclaimer.</span></div>
<div class="line"><span class="comment"> *       * Redistributions in binary form must reproduce the above copyright</span></div>
<div class="line"><span class="comment"> *         notice, this list of conditions and the following disclaimer in the</span></div>
<div class="line"><span class="comment"> *         documentation and/or other materials provided with the distribution.</span></div>
<div class="line"><span class="comment"> *       * Neither the name of Nokia Siemens Networks nor the</span></div>
<div class="line"><span class="comment"> *         names of its contributors may be used to endorse or promote products</span></div>
<div class="line"><span class="comment"> *         derived from this software without specific prior written permission.</span></div>
<div class="line"><span class="comment"> *</span></div>
<div class="line"><span class="comment"> *   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS &quot;AS IS&quot; AND</span></div>
<div class="line"><span class="comment"> *   ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED</span></div>
<div class="line"><span class="comment"> *   WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE</span></div>
<div class="line"><span class="comment"> *   DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY</span></div>
<div class="line"><span class="comment"> *   DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES</span></div>
<div class="line"><span class="comment"> *   (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;</span></div>
<div class="line"><span class="comment"> *   LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND</span></div>
<div class="line"><span class="comment"> *   ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT</span></div>
<div class="line"><span class="comment"> *   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS</span></div>
<div class="line"><span class="comment"> *   SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</span></div>
<div class="line"><span class="comment"> */</span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#include &quot;<a class="code" href="event__machine_8h.html" title="Event Machine API v1.0.">event_machine.h</a>&quot;</span></div>
<div class="line"><span class="preprocessor">#include &quot;environment.h&quot;</span></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#include &lt;inttypes.h&gt;</span></div>
<div class="line"><span class="preprocessor">#include &lt;string.h&gt;</span></div>
<div class="line"><span class="preprocessor">#include &lt;stdio.h&gt;</span></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#include &quot;example.h&quot;</span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#define NUM_EO            128</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"><span class="preprocessor">#define NUM_EVENT         8</span></div>
<div class="line"><span class="preprocessor"></span><span class="comment">//#define NUM_EVENT       256 // Try increasing the number of events to tune performance</span></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#define DATA_SIZE         512</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"><span class="preprocessor">#define MAX_NBR_OF_CORES  256</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"><span class="preprocessor">#define PRINT_EVENT_COUNT 0x400000</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"><span class="preprocessor">#define QUEUE_TYPE        EM_QUEUE_TYPE_ATOMIC</span></div>
<div class="line"><span class="preprocessor"></span><span class="comment">//#define QUEUE_TYPE      EM_QUEUE_TYPE_PARALLEL</span></div>
<div class="line"><span class="comment">//#define QUEUE_TYPE      EM_QUEUE_TYPE_PARALLEL_ORDERED</span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="comment">/*</span></div>
<div class="line"><span class="comment"> * Per event processing options</span></div>
<div class="line"><span class="comment"> */</span></div>
<div class="line"></div>
<div class="line"><span class="comment">//#define ALLOC_FREE_PER_EVENT</span></div>
<div class="line"></div>
<div class="line"><span class="comment">//#define MEMCPY_PER_EVENT</span></div>
<div class="line"></div>
<div class="line"><span class="comment">//#define CHECK_SEQ_PER_EVENT</span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="comment">/*</span></div>
<div class="line"><span class="comment"> * Note: The error macros below are NOT proper event machine error handling mechanisms.</span></div>
<div class="line"><span class="comment"> * For better error handling see the API funcs: em_error(), em_register_error_handler(),  </span></div>
<div class="line"><span class="comment"> * em_eo_register_error_handler() etc.</span></div>
<div class="line"><span class="comment"> */</span></div>
<div class="line"><span class="preprocessor">#define ERROR_PRINT(...)      {fprintf(stderr, &quot;\nAPPL ERROR: %s %s(line:%d) - EM-core%02i: &quot;, __FILE__, __func__, __LINE__, em_core_id()); \</span></div>
<div class="line"><span class="preprocessor">                               fprintf(stderr, __VA_ARGS__); fprintf(stderr, &quot;\n\n&quot;); abort();}</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"><span class="preprocessor">#define IS_ERROR(cond, ...)    \</span></div>
<div class="line"><span class="preprocessor">  if(ENV_UNLIKELY( (cond) )) { \</span></div>
<div class="line"><span class="preprocessor">    ERROR_PRINT(__VA_ARGS__);  \</span></div>
<div class="line"><span class="preprocessor">  }</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">typedef</span> <span class="keyword">union</span></div>
<div class="line">{</div>
<div class="line">  uint8_t u8[ENV_CACHE_LINE_SIZE] ENV_CACHE_LINE_ALIGNED;</div>
<div class="line"></div>
<div class="line">  <span class="keyword">struct</span></div>
<div class="line">  {</div>
<div class="line">    uint64_t events;</div>
<div class="line">    uint64_t begin_cycles;</div>
<div class="line">    uint64_t end_cycles;</div>
<div class="line">    uint64_t print_count;</div>
<div class="line">  };</div>
<div class="line"></div>
<div class="line">}perf_stat_t;</div>
<div class="line"></div>
<div class="line">COMPILE_TIME_ASSERT( <span class="keyword">sizeof</span>(perf_stat_t) == ENV_CACHE_LINE_SIZE,       PERF_STAT_T_SIZE_ERROR);</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">typedef</span> <span class="keyword">struct </span></div>
<div class="line">{</div>
<div class="line">  <a class="code" href="event__machine__types_8h.html#a1d373bd8469414626259c3ea14b5ee2a" title="Execution Object identifier.">em_eo_t</a> id;</div>
<div class="line">  </div>
<div class="line">  <span class="keywordtype">int</span> next_seq;</div>
<div class="line">  </div>
<div class="line">} eo_context_t;</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">typedef</span> <span class="keyword">union</span></div>
<div class="line">{</div>
<div class="line">  uint8_t u8[ENV_CACHE_LINE_SIZE] ENV_CACHE_LINE_ALIGNED;</div>
<div class="line">  </div>
<div class="line">  eo_context_t  eo_ctx;</div>
<div class="line">  </div>
<div class="line">} eo_context_array_elem_t;</div>
<div class="line"></div>
<div class="line">COMPILE_TIME_ASSERT(<span class="keyword">sizeof</span>(eo_context_array_elem_t) == ENV_CACHE_LINE_SIZE, PERF_EO_CONTEXT_SIZE_ERROR);</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">typedef</span> <span class="keyword">struct</span></div>
<div class="line">{</div>
<div class="line">  <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a> dest;</div>
<div class="line"></div>
<div class="line">  <span class="keywordtype">int</span> seq;</div>
<div class="line"></div>
<div class="line">  uint8_t data[DATA_SIZE];</div>
<div class="line"></div>
<div class="line">} perf_event_t;</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">typedef</span> <span class="keyword">struct</span></div>
<div class="line">{</div>
<div class="line">  eo_context_array_elem_t  perf_eo_context[NUM_EO]  ENV_CACHE_LINE_ALIGNED;</div>
<div class="line">  </div>
<div class="line">  perf_stat_t  core_stat[MAX_NBR_OF_CORES]  ENV_CACHE_LINE_ALIGNED;  </div>
<div class="line">  </div>
<div class="line">} perf_shm_t;</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> ENV_LOCAL perf_shm_t *perf_shm = NULL;</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="comment">/* </span></div>
<div class="line"><span class="comment"> * Local function prototypes</span></div>
<div class="line"><span class="comment"> */</span></div>
<div class="line"><span class="keyword">static</span> <a class="code" href="event__machine__types_8h.html#a125a101c5db94235eb758c8c32ab2628" title="Error/Status code.">em_status_t</a></div>
<div class="line">perf_start(<span class="keywordtype">void</span>* eo_context, <a class="code" href="event__machine__types_8h.html#a1d373bd8469414626259c3ea14b5ee2a" title="Execution Object identifier.">em_eo_t</a> eo);</div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <a class="code" href="event__machine__types_8h.html#a125a101c5db94235eb758c8c32ab2628" title="Error/Status code.">em_status_t</a></div>
<div class="line">perf_stop(<span class="keywordtype">void</span>* eo_context, <a class="code" href="event__machine__types_8h.html#a1d373bd8469414626259c3ea14b5ee2a" title="Execution Object identifier.">em_eo_t</a> eo);</div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span></div>
<div class="line">perf_receive_a(<span class="keywordtype">void</span>* eo_context, em_event_t event, <a class="code" href="event__machine__types_8h.html#a2f5b3fb43add8103da34b52cc1d0f2cc" title="Event type.">em_event_type_t</a> type, <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a> queue, <span class="keywordtype">void</span>* q_ctx);</div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span></div>
<div class="line">perf_receive_b(<span class="keywordtype">void</span>* eo_context, em_event_t event, <a class="code" href="event__machine__types_8h.html#a2f5b3fb43add8103da34b52cc1d0f2cc" title="Event type.">em_event_type_t</a> type, <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a> queue, <span class="keywordtype">void</span>* q_ctx);</div>
<div class="line"> </div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span></div>
<div class="line">print_result(perf_stat_t *<span class="keyword">const</span> perf_stat);</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keywordtype">void</span></div>
<div class="line">test_init(appl_conf_t *<span class="keyword">const</span> appl_conf)</div>
<div class="line">{</div>
<div class="line">  <a class="code" href="event__machine__types_8h.html#a1d373bd8469414626259c3ea14b5ee2a" title="Execution Object identifier.">em_eo_t</a>          eo;</div>
<div class="line">  eo_context_t*    eo_ctx;</div>
<div class="line">  <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a>       queue_a, queue_b;</div>
<div class="line">  em_event_t       event;</div>
<div class="line">  perf_event_t*    perf;</div>
<div class="line">  <a class="code" href="event__machine__types_8h.html#a125a101c5db94235eb758c8c32ab2628" title="Error/Status code.">em_status_t</a>      ret;</div>
<div class="line">  <span class="keywordtype">int</span>              i, j;</div>
<div class="line">  </div>
<div class="line"></div>
<div class="line">  <span class="keywordflow">if</span>(<a name="a0"></a><a class="code" href="event__machine_8h.html#a13d21af31382ec2c3d45010645707e9c" title="Logical core id.">em_core_id</a>() == 0) {</div>
<div class="line">    perf_shm = env_shared_reserve(<span class="stringliteral">&quot;PerfSharedMem&quot;</span>, <span class="keyword">sizeof</span>(perf_shm_t));</div>
<div class="line">  }</div>
<div class="line">  <span class="keywordflow">else</span> {</div>
<div class="line">    perf_shm = env_shared_lookup(<span class="stringliteral">&quot;PerfSharedMem&quot;</span>);</div>
<div class="line">  }</div>
<div class="line"></div>
<div class="line"></div>
<div class="line">  <span class="keywordflow">if</span>(perf_shm == NULL) {</div>
<div class="line">    <a name="a1"></a><a class="code" href="event__machine_8h.html#a1d45cd3fa718f99bce956904b5e081de" title="Report an error.">em_error</a>(EM_ERROR_SET_FATAL(0xec0de), 0xdead, <span class="stringliteral">&quot;Perf init failed on EM-core:%u\n&quot;</span>, <a class="code" href="event__machine_8h.html#a13d21af31382ec2c3d45010645707e9c" title="Logical core id.">em_core_id</a>());</div>
<div class="line">  }</div>
<div class="line">    </div>
<div class="line"></div>
<div class="line">  <span class="comment">/*</span></div>
<div class="line"><span class="comment">   * Rest of the initializations only on one EM-core, return on all others.</span></div>
<div class="line"><span class="comment">   */</span>  </div>
<div class="line">  <span class="keywordflow">if</span>(<a class="code" href="event__machine_8h.html#a13d21af31382ec2c3d45010645707e9c" title="Logical core id.">em_core_id</a>() != 0)</div>
<div class="line">  {</div>
<div class="line">    <span class="keywordflow">return</span>;</div>
<div class="line">  }</div>
<div class="line">  </div>
<div class="line"></div>
<div class="line">  printf(<span class="stringliteral">&quot;\n**********************************************************************\n&quot;</span></div>
<div class="line">         <span class="stringliteral">&quot;EM APPLICATION: &#39;%s&#39; initializing: \n&quot;</span></div>
<div class="line">         <span class="stringliteral">&quot;  %s: %s() - EM-core:%i \n&quot;</span></div>
<div class="line">         <span class="stringliteral">&quot;  Application running on %d EM-cores (procs:%d, threads:%d).&quot;</span></div>
<div class="line">         <span class="stringliteral">&quot;\n**********************************************************************\n&quot;</span></div>
<div class="line">         <span class="stringliteral">&quot;\n&quot;</span></div>
<div class="line">         ,</div>
<div class="line">         appl_conf-&gt;name,</div>
<div class="line">         NO_PATH(__FILE__), __func__,</div>
<div class="line">         <a class="code" href="event__machine_8h.html#a13d21af31382ec2c3d45010645707e9c" title="Logical core id.">em_core_id</a>(),</div>
<div class="line">         <a name="a2"></a><a class="code" href="event__machine_8h.html#a84fa6ec801b82a586ff5e31693d3deb8" title="The number of cores running within the same EM instance (sharing the EM state).">em_core_count</a>(),</div>
<div class="line">         appl_conf-&gt;num_procs,</div>
<div class="line">         appl_conf-&gt;num_threads);</div>
<div class="line">         </div>
<div class="line">           </div>
<div class="line">  (void) memset(perf_shm-&gt;core_stat, 0, <span class="keyword">sizeof</span>(perf_shm-&gt;core_stat));</div>
<div class="line"></div>
<div class="line">  <span class="comment">/*</span></div>
<div class="line"><span class="comment">   * Create and start application pairs</span></div>
<div class="line"><span class="comment">   * Send initial test events to the queues</span></div>
<div class="line"><span class="comment">   */</span></div>
<div class="line">  <span class="keywordflow">for</span>(i = 0; i &lt; (NUM_EO/2); i++)</div>
<div class="line">  {</div>
<div class="line">    <span class="comment">/*</span></div>
<div class="line"><span class="comment">     * Create EO &quot;A&quot;</span></div>
<div class="line"><span class="comment">     */</span></div>
<div class="line">    eo_ctx = &amp;perf_shm-&gt;perf_eo_context[2*i].eo_ctx;</div>
<div class="line"></div>
<div class="line">    eo      = <a name="a3"></a><a class="code" href="event__machine_8h.html#a196c7caa1177575fd424e9a0d2854da6" title="Create Execution Object (EO).">em_eo_create</a>(<span class="stringliteral">&quot;appl a&quot;</span>, perf_start, NULL, perf_stop, NULL, perf_receive_a, eo_ctx);</div>
<div class="line">    queue_a = <a name="a4"></a><a class="code" href="event__machine_8h.html#a15c0cb536f8c7c01692ccea07908944a" title="Create a new queue with a dynamic queue id.">em_queue_create</a>(<span class="stringliteral">&quot;queue A&quot;</span>, QUEUE_TYPE, EM_QUEUE_PRIO_NORMAL, EM_QUEUE_GROUP_DEFAULT);</div>
<div class="line"></div>
<div class="line">    eo_ctx-&gt;next_seq = 0;</div>
<div class="line"></div>
<div class="line">    ret = <a name="a5"></a><a class="code" href="event__machine_8h.html#a681c9d79f7ca5c0590030f74357472c0" title="Add a queue to an EO.">em_eo_add_queue</a>(eo, queue_a);</div>
<div class="line">    IS_ERROR(ret != <a name="a6"></a><a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>, <span class="stringliteral">&quot;EO or queue creation failed (%u). EO: %&quot;</span><a name="a7"></a><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;, queue: %&quot;</span><a name="a8"></a><a class="code" href="event__machine__types_8h.html#a0331964318f921644a88d3cc38c122e5" title="em_queue_t printf format">PRI_QUEUE</a><span class="stringliteral">&quot;\n&quot;</span>, ret, eo, queue_a);</div>
<div class="line"></div>
<div class="line">    ret = <a name="a9"></a><a class="code" href="event__machine_8h.html#a97445f266a00782bb23fc2c464533d6d" title="Start Execution Object (EO).">em_eo_start</a>(eo, NULL, 0, NULL);</div>
<div class="line">    IS_ERROR(ret != <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>, <span class="stringliteral">&quot;EO start failed (%u). EO: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;\n&quot;</span>, ret, eo);</div>
<div class="line"></div>
<div class="line">    ret = <a name="a10"></a><a class="code" href="event__machine_8h.html#adcbab74b22ffcb629bdf797704ac2706" title="Enable event scheduling for the queue.">em_queue_enable</a>(queue_a);</div>
<div class="line">    IS_ERROR(ret != <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>, <span class="stringliteral">&quot;Queue A enable failed (%u). EO: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;, queue: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0331964318f921644a88d3cc38c122e5" title="em_queue_t printf format">PRI_QUEUE</a><span class="stringliteral">&quot;\n&quot;</span>, ret, eo, queue_a);</div>
<div class="line"></div>
<div class="line"></div>
<div class="line">    <span class="comment">/*</span></div>
<div class="line"><span class="comment">     * Create EO &quot;B&quot;</span></div>
<div class="line"><span class="comment">     */</span></div>
<div class="line">    eo_ctx = &amp;perf_shm-&gt;perf_eo_context[2*i + 1].eo_ctx;</div>
<div class="line"></div>
<div class="line">    eo      = <a class="code" href="event__machine_8h.html#a196c7caa1177575fd424e9a0d2854da6" title="Create Execution Object (EO).">em_eo_create</a>(<span class="stringliteral">&quot;appl b&quot;</span>, perf_start, NULL, perf_stop, NULL, perf_receive_b, eo_ctx);</div>
<div class="line">    queue_b = <a class="code" href="event__machine_8h.html#a15c0cb536f8c7c01692ccea07908944a" title="Create a new queue with a dynamic queue id.">em_queue_create</a>(<span class="stringliteral">&quot;queue B&quot;</span>, QUEUE_TYPE, EM_QUEUE_PRIO_NORMAL, EM_QUEUE_GROUP_DEFAULT);</div>
<div class="line"></div>
<div class="line">    eo_ctx-&gt;next_seq = NUM_EVENT/2;</div>
<div class="line"></div>
<div class="line">    ret = <a class="code" href="event__machine_8h.html#a681c9d79f7ca5c0590030f74357472c0" title="Add a queue to an EO.">em_eo_add_queue</a>(eo, queue_b);</div>
<div class="line">    IS_ERROR(ret != <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>, <span class="stringliteral">&quot;EO or queue creation failed (%u). EO: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;, queue: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0331964318f921644a88d3cc38c122e5" title="em_queue_t printf format">PRI_QUEUE</a><span class="stringliteral">&quot;\n&quot;</span>, ret, eo, queue_b);</div>
<div class="line"></div>
<div class="line">    ret = <a class="code" href="event__machine_8h.html#a97445f266a00782bb23fc2c464533d6d" title="Start Execution Object (EO).">em_eo_start</a>(eo, NULL, 0, NULL);</div>
<div class="line">    IS_ERROR(ret != <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>, <span class="stringliteral">&quot;EO start failed (%i). EO: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;\n&quot;</span>, ret, eo);</div>
<div class="line">    </div>
<div class="line">    ret = <a class="code" href="event__machine_8h.html#adcbab74b22ffcb629bdf797704ac2706" title="Enable event scheduling for the queue.">em_queue_enable</a>(queue_b);                                                                              </div>
<div class="line">    IS_ERROR(ret != <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>, <span class="stringliteral">&quot;Queue B enable failed (%u). EO: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;, queue: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0331964318f921644a88d3cc38c122e5" title="em_queue_t printf format">PRI_QUEUE</a><span class="stringliteral">&quot;\n&quot;</span>, ret, eo, queue_b);</div>
<div class="line">    </div>
<div class="line">    </div>
<div class="line">    <span class="comment">/*</span></div>
<div class="line"><span class="comment">     * Alloc and send test events</span></div>
<div class="line"><span class="comment">     */</span></div>
<div class="line">    <span class="keywordflow">for</span>(j = 0; j &lt; NUM_EVENT; j++)</div>
<div class="line">    {</div>
<div class="line">      <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a> first_q;</div>
<div class="line">      </div>
<div class="line">      <span class="keyword">event</span> = <a name="a11"></a><a class="code" href="event__machine_8h.html#a22fcb41f303628eebe4f0b45b6c64ab0" title="Allocate an event.">em_alloc</a>(<span class="keyword">sizeof</span>(perf_event_t), EM_EVENT_TYPE_SW, EM_POOL_DEFAULT);</div>
<div class="line">      IS_ERROR(event == EM_EVENT_UNDEF, <span class="stringliteral">&quot;Event allocation failed (%i, %i)\n&quot;</span>, i, j);</div>
<div class="line">      </div>
<div class="line">      perf = em_event_pointer(event);</div>
<div class="line"></div>
<div class="line">      </div>
<div class="line">      <span class="keywordflow">if</span>(j &amp; 0x1) </div>
<div class="line">      {</div>
<div class="line">        <span class="comment">// Odd: j = 1, 3, 5, ...</span></div>
<div class="line">        perf-&gt;seq  = NUM_EVENT/2 + j/2;  <span class="comment">// 4, 5, 6, 7, ...  (NUM_EVENT/2 ... NUM_EVENT - 1)</span></div>
<div class="line">        first_q    = queue_b;</div>
<div class="line">        perf-&gt;dest = queue_a;</div>
<div class="line">      }</div>
<div class="line">      <span class="keywordflow">else</span></div>
<div class="line">      {</div>
<div class="line">        <span class="comment">// Even: j = 0, 2, 4, ...</span></div>
<div class="line">        perf-&gt;seq  = j/2;                <span class="comment">// 0, 1, 2, 3, ...  (0 ... NUM_EVENT/2 - 1)   </span></div>
<div class="line">        first_q    = queue_a;</div>
<div class="line">        perf-&gt;dest = queue_b;</div>
<div class="line">      }</div>
<div class="line"></div>
<div class="line"></div>
<div class="line">      ret = <a name="a12"></a><a class="code" href="event__machine_8h.html#aca4584a01b71429dfbb045342454b464" title="Send an event to a queue.">em_send</a>(event, first_q);</div>
<div class="line">      IS_ERROR(ret != <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>, <span class="stringliteral">&quot;Event send failed (%u)! Queue: %&quot;</span><a class="code" href="event__machine__types_8h.html#a0331964318f921644a88d3cc38c122e5" title="em_queue_t printf format">PRI_QUEUE</a><span class="stringliteral">&quot; \n&quot;</span>, ret, first_q);</div>
<div class="line">    }</div>
<div class="line"></div>
<div class="line">  }</div>
<div class="line">  </div>
<div class="line"></div>
<div class="line">  env_sync_mem();</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <a class="code" href="event__machine__types_8h.html#a125a101c5db94235eb758c8c32ab2628" title="Error/Status code.">em_status_t</a></div>
<div class="line">perf_start(<span class="keywordtype">void</span>* eo_context, <a class="code" href="event__machine__types_8h.html#a1d373bd8469414626259c3ea14b5ee2a" title="Execution Object identifier.">em_eo_t</a> eo)</div>
<div class="line">{</div>
<div class="line">  eo_context_t* eo_ctx = eo_context;</div>
<div class="line">  </div>
<div class="line">  printf(<span class="stringliteral">&quot;EO %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot; starting.\n&quot;</span>, eo);</div>
<div class="line"></div>
<div class="line">  eo_ctx-&gt;id = eo;</div>
<div class="line"></div>
<div class="line">  <span class="keywordflow">return</span> <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>;</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <a class="code" href="event__machine__types_8h.html#a125a101c5db94235eb758c8c32ab2628" title="Error/Status code.">em_status_t</a></div>
<div class="line">perf_stop(<span class="keywordtype">void</span>* eo_context, <a class="code" href="event__machine__types_8h.html#a1d373bd8469414626259c3ea14b5ee2a" title="Execution Object identifier.">em_eo_t</a> eo)</div>
<div class="line">{</div>
<div class="line">  printf(<span class="stringliteral">&quot;EO %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot; stopping.\n&quot;</span>, eo);</div>
<div class="line"></div>
<div class="line">  <span class="keywordflow">return</span> <a class="code" href="event__machine__types_8h.html#a03546e6a7e93665c52d479831e0a6dca" title="Operation successful.">EM_OK</a>;</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span></div>
<div class="line">perf_receive_a(<span class="keywordtype">void</span>* eo_context, em_event_t event, <a class="code" href="event__machine__types_8h.html#a2f5b3fb43add8103da34b52cc1d0f2cc" title="Event type.">em_event_type_t</a> type, <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a> queue, <span class="keywordtype">void</span>* q_ctx)</div>
<div class="line">{</div>
<div class="line">  perf_event_t *perf;</div>
<div class="line">  <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a>    dest_queue;</div>
<div class="line">  <span class="keywordtype">int</span>           core;</div>
<div class="line">  uint64_t      events;</div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#ifdef CHECK_SEQ_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  <span class="keywordtype">int</span>           seq;</div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span>  </div>
<div class="line">  core   = <a class="code" href="event__machine_8h.html#a13d21af31382ec2c3d45010645707e9c" title="Logical core id.">em_core_id</a>();</div>
<div class="line">  events = perf_shm-&gt;core_stat[core].events;</div>
<div class="line">  perf   = em_event_pointer(event);</div>
<div class="line">  </div>
<div class="line">  dest_queue = perf-&gt;dest;</div>
<div class="line"></div>
<div class="line"></div>
<div class="line">  <span class="comment">/*</span></div>
<div class="line"><span class="comment">   * Update the cycle count and print results when necessary</span></div>
<div class="line"><span class="comment">   */</span></div>
<div class="line">  <span class="keywordflow">if</span>(ENV_UNLIKELY(events == 0))</div>
<div class="line">  {</div>
<div class="line">    perf_shm-&gt;core_stat[core].begin_cycles = env_get_cycle();</div>
<div class="line">    events += 1;</div>
<div class="line">  }</div>
<div class="line">  <span class="keywordflow">else</span> <span class="keywordflow">if</span>(ENV_UNLIKELY(events &gt; PRINT_EVENT_COUNT))</div>
<div class="line">  {</div>
<div class="line">    perf_shm-&gt;core_stat[core].end_cycles   = env_get_cycle();</div>
<div class="line">    perf_shm-&gt;core_stat[core].print_count += 1;</div>
<div class="line">    </div>
<div class="line">    <span class="comment">/* Print measurement result */</span></div>
<div class="line">    print_result(&amp;perf_shm-&gt;core_stat[core]);</div>
<div class="line">    </div>
<div class="line">    <span class="comment">/* Restart the measurement */</span></div>
<div class="line">    perf_shm-&gt;core_stat[core].begin_cycles = env_get_cycle();</div>
<div class="line">    events = 0;</div>
<div class="line">  }</div>
<div class="line">  <span class="keywordflow">else</span> {</div>
<div class="line">    events += 1;</div>
<div class="line">  }</div>
<div class="line">  </div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#ifdef CHECK_SEQ_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  seq = perf-&gt;seq;</div>
<div class="line">  </div>
<div class="line">  <span class="keywordflow">if</span>(ENV_UNLIKELY(seq != eo_ctx-&gt;next_seq))</div>
<div class="line">  {</div>
<div class="line">    printf(<span class="stringliteral">&quot;Bad sequence number. EO(A) %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;, queue %&quot;</span><a class="code" href="event__machine__types_8h.html#a0331964318f921644a88d3cc38c122e5" title="em_queue_t printf format">PRI_QUEUE</a><span class="stringliteral">&quot;, expected seq %i, event seq %i \n&quot;</span>,</div>
<div class="line">           eo_ctx-&gt;id, queue, eo_ctx-&gt;next_seq, seq);</div>
<div class="line">  }</div>
<div class="line">  </div>
<div class="line">  <span class="keywordflow">if</span>(ENV_LIKELY(eo_ctx-&gt;next_seq &lt; (NUM_EVENT - 1))) {</div>
<div class="line">    eo_ctx-&gt;next_seq++;</div>
<div class="line">  }</div>
<div class="line">  <span class="keywordflow">else</span> {</div>
<div class="line">    eo_ctx-&gt;next_seq = 0;</div>
<div class="line">  }</div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#ifdef MEMCPY_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  {</div>
<div class="line">    uint8_t* from = &amp;perf-&gt;data[0];</div>
<div class="line">    uint8_t* to   = &amp;perf-&gt;data[DATA_SIZE/2];</div>
<div class="line">    </div>
<div class="line">    memcpy(to, from, DATA_SIZE/2);</div>
<div class="line">  }</div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#ifdef ALLOC_FREE_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  <a name="a13"></a><a class="code" href="event__machine_8h.html#ad4f97ba217518d967f8078c56023c4d4" title="Free an event.">em_free</a>(event);  </div>
<div class="line">  <span class="keyword">event</span> = <a class="code" href="event__machine_8h.html#a22fcb41f303628eebe4f0b45b6c64ab0" title="Allocate an event.">em_alloc</a>(<span class="keyword">sizeof</span>(perf_event_t), EM_EVENT_TYPE_SW, EM_POOL_DEFAULT);</div>
<div class="line">  perf  = em_event_pointer(event);</div>
<div class="line"></div>
<div class="line"><span class="preprocessor">  #ifdef CHECK_SEQ_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  perf-&gt;seq = seq;</div>
<div class="line"><span class="preprocessor">  #endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span>  </div>
<div class="line">  </div>
<div class="line">  perf-&gt;dest = queue;</div>
<div class="line"></div>
<div class="line">  <a class="code" href="event__machine_8h.html#aca4584a01b71429dfbb045342454b464" title="Send an event to a queue.">em_send</a>(event, dest_queue);</div>
<div class="line"></div>
<div class="line">  perf_shm-&gt;core_stat[core].events = events;</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span></div>
<div class="line">perf_receive_b(<span class="keywordtype">void</span>* eo_context, em_event_t event, <a class="code" href="event__machine__types_8h.html#a2f5b3fb43add8103da34b52cc1d0f2cc" title="Event type.">em_event_type_t</a> type, <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a> queue, <span class="keywordtype">void</span>* q_ctx)</div>
<div class="line">{</div>
<div class="line">  perf_event_t *perf;</div>
<div class="line">  <a class="code" href="event__machine__types_8h.html#a43cb5a167efa542d81180a54915d99bf" title="Queue identifier.">em_queue_t</a>    dest_queue;</div>
<div class="line">  <span class="keywordtype">int</span>           core;</div>
<div class="line">  uint64_t      events;</div>
<div class="line">  </div>
<div class="line"><span class="preprocessor">#ifdef CHECK_SEQ_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  <span class="keywordtype">int</span>           seq;</div>
<div class="line">  eo_context_t* eo_ctx = eo_context;</div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"></div>
<div class="line">  perf = em_event_pointer(event);</div>
<div class="line"></div>
<div class="line">  dest_queue = perf-&gt;dest;</div>
<div class="line"></div>
<div class="line">  </div>
<div class="line"><span class="preprocessor">#ifdef CHECK_SEQ_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  seq = perf-&gt;seq;</div>
<div class="line">  </div>
<div class="line">  <span class="keywordflow">if</span>(ENV_UNLIKELY(seq != eo_ctx-&gt;next_seq))</div>
<div class="line">  {</div>
<div class="line">    printf(<span class="stringliteral">&quot;Bad sequence number. EO(B) %&quot;</span><a class="code" href="event__machine__types_8h.html#a0bf4a25d46e18ee918e684e5deb27fa4" title="em_eo_t printf format">PRI_EO</a><span class="stringliteral">&quot;, queue %&quot;</span><a class="code" href="event__machine__types_8h.html#a0331964318f921644a88d3cc38c122e5" title="em_queue_t printf format">PRI_QUEUE</a><span class="stringliteral">&quot;, expected seq %i, event seq %i \n&quot;</span>,</div>
<div class="line">           eo_ctx-&gt;id, queue, eo_ctx-&gt;next_seq, seq);</div>
<div class="line">  }</div>
<div class="line"></div>
<div class="line">  <span class="keywordflow">if</span>(ENV_LIKELY(eo_ctx-&gt;next_seq &lt; (NUM_EVENT - 1))) {</div>
<div class="line">    eo_ctx-&gt;next_seq++;</div>
<div class="line">  }</div>
<div class="line">  <span class="keywordflow">else</span> {</div>
<div class="line">    eo_ctx-&gt;next_seq = 0;</div>
<div class="line">  }</div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#ifdef MEMCPY_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  {</div>
<div class="line">    uint8_t* from = &amp;perf-&gt;data[DATA_SIZE/2];</div>
<div class="line">    uint8_t* to   = &amp;perf-&gt;data[0];</div>
<div class="line"></div>
<div class="line">    memcpy(to, from, DATA_SIZE/2);</div>
<div class="line">  }</div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="preprocessor">#ifdef ALLOC_FREE_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  <a class="code" href="event__machine_8h.html#ad4f97ba217518d967f8078c56023c4d4" title="Free an event.">em_free</a>(event);</div>
<div class="line">  <span class="keyword">event</span> = <a class="code" href="event__machine_8h.html#a22fcb41f303628eebe4f0b45b6c64ab0" title="Allocate an event.">em_alloc</a>(<span class="keyword">sizeof</span>(perf_event_t), EM_EVENT_TYPE_SW, EM_POOL_DEFAULT);</div>
<div class="line">  perf  = em_event_pointer(event);</div>
<div class="line">  </div>
<div class="line"><span class="preprocessor">  #ifdef CHECK_SEQ_PER_EVENT</span></div>
<div class="line"><span class="preprocessor"></span>  perf-&gt;seq = seq;</div>
<div class="line"><span class="preprocessor">  #endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"><span class="preprocessor">#endif</span></div>
<div class="line"><span class="preprocessor"></span></div>
<div class="line"></div>
<div class="line">  core   = <a class="code" href="event__machine_8h.html#a13d21af31382ec2c3d45010645707e9c" title="Logical core id.">em_core_id</a>();</div>
<div class="line">  events = perf_shm-&gt;core_stat[core].events + 1;</div>
<div class="line"></div>
<div class="line"></div>
<div class="line">  perf-&gt;dest = queue;</div>
<div class="line"></div>
<div class="line">  <a class="code" href="event__machine_8h.html#aca4584a01b71429dfbb045342454b464" title="Send an event to a queue.">em_send</a>(event, dest_queue);</div>
<div class="line"></div>
<div class="line">  perf_shm-&gt;core_stat[core].events = events;</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span></div>
<div class="line">print_result(perf_stat_t *<span class="keyword">const</span> perf_stat)</div>
<div class="line">{</div>
<div class="line">    uint64_t diff;</div>
<div class="line">    uint32_t hz;</div>
<div class="line">    <span class="keywordtype">double</span>   mhz;</div>
<div class="line">    <span class="keywordtype">double</span>   cycles_per_event;</div>
<div class="line">    uint64_t print_count;</div>
<div class="line"></div>
<div class="line"></div>
<div class="line">    diff             = perf_stat-&gt;end_cycles - perf_stat-&gt;begin_cycles;</div>
<div class="line">    print_count      = perf_stat-&gt;print_count;</div>
<div class="line">    cycles_per_event = ((double) diff) / ((double) perf_stat-&gt;events);</div>
<div class="line"></div>
<div class="line">    hz  = env_core_hz();</div>
<div class="line">    mhz = ((double) hz) / 1000000.0;</div>
<div class="line"></div>
<div class="line">    printf(<span class="stringliteral">&quot;cycles per event %.2f  @%.2f MHz (core-%02i %&quot;</span>PRIu64<span class="stringliteral">&quot;)\n&quot;</span>, cycles_per_event, mhz, <a class="code" href="event__machine_8h.html#a13d21af31382ec2c3d45010645707e9c" title="Logical core id.">em_core_id</a>(), print_count);</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"></div>
<div class="line"></div>
</div><!-- fragment --> </div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Generated on Wed Aug 7 2013 15:17:39 for Open Event Machine API by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.3.1 </li>
  </ul>
</div>
</body>
</html>
